import fetch from 'fetch'

export default {
  global () {
    return fetch({url: '/v1/guest/adList?adsType=banner&showPosition=45&rows=10'})
  },
  login (data, context) {
    return fetch({
      method: 'POST',
      url: '/v1/user/_guest/login',
      data,
      context
    })
  },
  getUserInfo (params) {
    return fetch({
      url: '/v1/user/_guest/login',
      params
    })
  },
  getIpGrantRole () {
    return fetch({
      url: '/v1/user/user/getIpGrantRole'
    })
  },
  getIpOrgGrantRole (params) {
    return fetch({
      url: '/v1/user/user/getIpOrgGrantRole',
      params
    })
  }
}
